# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=sbd
pkgver=1.36
pkgrel=8
groups=('blackarch' 'blackarch-crypto' 'blackarch-networking')
pkgdesc="Netcat-clone, portable, offers strong encryption - features AES-128-CBC + HMAC-SHA1 encryption, program execution (-e), choosing source port, continuous reconnection with delay + more"
url='http://www2.packetstormsecurity.org/cgi-bin/search/search.cgi?searchvalue=sbd'
arch=('x86_64' 'aarch64')
license=('GPL')
source=("https://dl.packetstormsecurity.net/UNIX/netcat/$pkgname-$pkgver.tar.gz")
sha512sums=('b980bcc492c112682a989780c9a362e95d50f7d1efd36eccbf5107409762f32b7d590f8d123da750ca091e0607bd4cd88a1124a17ff41c0615a4054aef53403b')

build() {
  cd "$pkgname-$pkgver"

  make unix
}

package() {
  cd "$pkgname-$pkgver"

  install -dm 755 "$pkgdir/usr/bin"

  install -Dm 755 "$srcdir/sbd-$pkgver/sbd" "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README CHANGES
  install -Dm 644 COPYING "$pkgdir/usr/share/licenses/sbd/COPYING"
}

